// JavaScript Document

function sideLab(){

	var oLab=document.getElementById('sidelab_top').getElementsByTagName('div');
	var oLabCont=document.getElementById('sidelab_cont').getElementsByTagName('span');
	//alert(oLabCont.length);
	
	var i=0;
	
	for(i=0;i<oLab.length;i++){
		
		oLab[i].index=i;
		oLab[i].onclick=function(){
			
			for(i=0;i<oLab.length;i++){
			
				oLab[i].className='sidelab_main';
				oLabCont[i].style.display='none';
			
			}
		
			//alert(oLab.length);
			this.className='sidelab_maincur';
			oLabCont[this.index].style.display='block';
		
		}
	
	}
}

function sideLabSex(){
	
	var oLabSex=document.getElementById('sidelab_sex').getElementsByTagName('div');
	
	var i=0;
	
	for(i=0;i<oLabSex.length;i++){
		
		oLabSex[i].onclick=function(){
			
			for(i=0;i<oLabSex.length;i++){
			
				oLabSex[i].className='sidelab_sex';
			
			}
		
			//alert(oLab.length);
			this.className='sidelab_sexcur';
		
		}
	
	}

}

function sideLabGoods(){
	
	var oLabGoods=document.getElementById('sidelab_goods').getElementsByTagName('div');
	
	var i=0;
	
	for(i=0;i<oLabGoods.length;i++){
		
		oLabGoods[i].onclick=function(){
			
			for(i=0;i<oLabGoods.length;i++){
			
				oLabGoods[i].className='sidelab_sex';
			
			}
		
			//alert(oLab.length);
			this.className='sidelab_sexcur';
		
		}
	
	}

}

function sideLabGoods02(){
	
	var oLabGoods02=document.getElementById('sidelab_goods02').getElementsByTagName('div');
	
	var i=0;
	
	for(i=0;i<oLabGoods02.length;i++){
		
		oLabGoods02[i].onclick=function(){
			
			for(i=0;i<oLabGoods02.length;i++){
			
				oLabGoods02[i].className='sidelab_sex';
			
			}
		
			//alert(oLab.length);
			this.className='sidelab_sexcur';
		
		}
	
	}

}

//会员中-心点击圆按钮展开/隐藏
function centerSidebar(){

	var oBtn=document.getElementById('personal_sidebar').getElementsByTagName('span');
	var oUl=document.getElementById('personal_sidebar').getElementsByTagName('ul');
	//alert(oLabCont.length);
	
	var i=0;
	
	for(i=0;i<oBtn.length;i++){
		
		oBtn[i].index=i;
		oBtn[i].onclick=function(){
			
			for(i=0;i<oBtn.length;i++){
			
				oBtn[i].className='personal_sidebar_icodown';
				oUl[i].style.display='none';
			
			}
		
			//alert(oLab.length);
			this.className='personal_sidebar_icoup';
			oUl[this.index].style.display='block';
		
		}
	
	}
}

//体检预约流程页面标签切换
function bespeakLab(){
	var oLab=document.getElementById('bespeak_top').getElementsByTagName('div');
	var oLabCont=document.getElementById('bespeak_main').getElementsByTagName('span');
	//alert(oLabCont.length);
	var i=0;
	for(i=0;i<oLab.length;i++){
		
		oLab[i].index=i;
		oLab[i].onclick=function(){
			for(i=0;i<oLab.length;i++){
				oLab[i].className='procedure_bespeak_lab';
				oLabCont[i].style.display='none';
			}
			//alert(oLab.length);
			this.className='procedure_bespeak_labcur';
			oLabCont[this.index].style.display='block';
		}
	}
}

//体检预约流程页面-体检机构展开
function bespeakOpen(){

	var oMain=document.getElementById('procedure_bespeak_main');
	var oUl=document.getElementById('procedure_bespeak_ul');
	var oMore=document.getElementById('procedure_bespeak_more');
	//alert(oUl);
	
	oMore.onclick=function(){
		if(oMore.innerHTML=='更多+'){
			oMain.style.height=oUl.offsetHeight+'px';
			this.innerHTML='收起-';
		}else{
			oMain.style.height=80+'px';
			this.innerHTML='更多+';
		}
	}
}















